<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>$Title$</title>
</head>
<script src="${pageContext.request.contextPath}/js/jquery-3.4.1.js"></script>
<script>
    window.onload = function () {
        $.get("http://localhost:8080/user/find", "", function (data) {
            var user = $("#user");
            var str = "";
            var userdata = data.data;
            for (var i in userdata) {
                str += '<tr>'+
                            '<td>'+userdata[i].id+'</td>'+
                            '<td>'+userdata[i].username+'</td>'+
                            '<td>'+userdata[i].password+'</td>'+
                            '<td>'+userdata[i].status+'</td>'+
                        '</tr>';
            }
            user.append(str);
        },"json")
    }
</script>
<body>
    我进来咯
    <table id="user">
        <tr>
            <th>id</th>
            <th>姓名</th>
            <th>密码</th>
            <th>状态</th>
        </tr>
        <tr>
            <td>1</td>
            <td>====</td>
            <td>====</td>
            <td>====</td>
        </tr>
    </table>
</body>
</html>
